﻿<?php
if(isset($_POST["rid"]))
{
$rid = $_POST["rid"];
$name = $_POST["name"];

$db = mysql_connect("mysql513.in.shared-server.net:16033", "JRtu434", "qvoiceDB1");
 mysql_select_db("JRtu434", $db);
 mysql_query("SET NAMES utf8");
 echo $_POST["name"];
 mysql_query("Insert into spireproject (rid,name) values(\"".$_POST["rid"]."\",\"".$_POST["name"]."\")");
 mysql_close();
 }
?> 
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>手動プロジェクト登録</title>
</head>
<body>
	<div id="content">
		<form method="post" action="<?php echo htmlentities($_SERVER['PHP_SELF']); ?>">
		<table>
			<tr>
				<td>
					RID（暗号）<input type="text" size="30" maxlength="30" name="rid" placeholder="ＰＯＳＴ プロジェクト暗号">
				</td>
				<td>
					調査名： <input type="text" size="30" maxlength="60" name="name" placeholder="調査名">
				</td>
			</tr>
			<tr>
				<td colspan="2" align="center">
					<input type="submit" value="submit" name="submit">
				</td>
			</tr>
		</table>
		</form>
	</div>
</body>
</html>
